#自定义异常，需要继承Exception基类
class MyError(Exception):
	pass;

def func():
	raise MyError('私人定制');
	print('do something');

print('start');
func();		